<?php

if (is_logged()) {
?>
<!--DEBUT CONTENT-->
<div class="content">
    <h1>Espace perso Learn AfterPiscine</h1>
    <?php
	if($_POST!=NULL)
	{
		if($_POST['jour'] == 'un')
		{
		echo '<object data="../doc/ordinateur.pdf" type="application/pdf" width="850" height="800">
  		alt : <a href="../doc/ordinateur.pdf">test.pdf</a>
		</object>';
		}
		else if($_POST['jour'] == 'deux')
		{
		echo '<object data="../doc/ordinateur.pdf" type="application/pdf" width="850" height="800">
  		alt : <a href="../doc/ordinateur.pdf">test.pdf</a>
		</object>';
		}
		else if($_POST['jour'] == 'trois')
		{
		echo '<object data="../doc/ordinateur.pdf" type="application/pdf" width="850" height="800">
  		alt : <a href="../doc/ordinateur.pdf">test.pdf</a>
		</object>';
		}
		else if($_POST['jour'] == 'quatre')
		{
		echo '<object data="../doc/ordinateur.pdf" type="application/pdf" width="850" height="800">
  		alt : <a href="../doc/ordinateur.pdf">test.pdf</a>
		</object>';
		}
	}
	else{
	?>
    <h2>Veuillez s&eacute;lectionner un jour :</h2>

    <form action="index.php?page=elearning.php" method="post">
      <p><label for="jour"><strong>JOUR : </strong></label>
	<select name="jour" id="jour">
	  <option selected="selected" value="un"> Jour 1 | PHP/HTML</option>
	  <option value="deux">Jour 2 | PHP/HTML</option>
	  <option value="trois">Jour 3 | TP1</option>
   	  <option value="quatre">Jour 4 | TP2</option>
	</select>
	<input name="submit" type="image" value="GOFORM" src="img/goform.jpg" alt="go" />
      </p>
    </form>
    <?php
       }
	?>
</div>
<!--FIN CONTENT-->
<?php
      }
else {
  include('txt/404.html');
}
?>
